package cn.qvtu.web.service.impl;

import cn.qvtu.web.domain.Article;
import cn.qvtu.web.mapper.ArticleMapper;
import cn.qvtu.web.service.IArticleService;
import cn.qvtu.web.vo.ArticleVO;
import cn.qvtu.web.vo.HotArticleVO;
import cn.qvtu.web.vo.LatestArticleVO;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author qvtu
 * @since 2024-04-22
 */
@Service
public class ArticleServiceImpl extends ServiceImpl<ArticleMapper, Article> implements IArticleService {

    @Autowired
    private ArticleMapper articleMapper;

    @Override
    public List<HotArticleVO> selectHotArticle() {
        return articleMapper.selectHotArticle();
    }

    @Override
    public List<LatestArticleVO> selectLatestArticle() {
        return articleMapper.selectLatestArticle();
    }
    @Override
    public List<ArticleVO> selectArticle() {
        return articleMapper.selectArticle();
    }


}
